3.11 \(\int \frac{\cos (x) \sin (x)}{x^2} \, dx\)

Optimal. Leaf size=16 \[ \text{CosIntegral}(2 x)-\frac{\sin (2 x)}{2 x} \]

[Out]

CosIntegral[2*x] - Sin[2*x]/(2*x)

________________________________________________________________________________________

Rubi [A]  time = 0.0457541, antiderivative size = 16, normalized size of antiderivative = 1., number of steps used = 4, number of rules used = 4, integrand size = 8, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.5, Rules used = {4406, 12, 3297, 3302} \[ \text{CosIntegral}(2 x)-\frac{\sin (2 x)}{2 x} \]

Antiderivative was successfully verified.

[In]

Int[(Cos[x]*Sin[x])/x^2,x]

[Out]

CosIntegral[2*x] - Sin[2*x]/(2*x)

Rule 4406

Int[Cos[(a_.) + (b_.)*(x_)]^(p_.)*((c_.) + (d_.)*(x_))^(m_.)*Sin[(a_.) + (b_.)*(x_)]^(n_.), x_Symbol] :> Int[E
xpandTrigReduce[(c + d*x)^m, Sin[a + b*x]^n*Cos[a + b*x]^p, x], x] /; FreeQ[{a, b, c, d, m}, x] && IGtQ[n, 0]
&& IGtQ[p, 0]

Rule 12

Int[(a_)*(u_), x_Symbol] :> Dist[a, Int[u, x], x] /; FreeQ[a, x] &&  !MatchQ[u, (b_)*(v_) /; FreeQ[b, x]]

Rule 3297

Int[((c_.) + (d_.)*(x_))^(m_)*sin[(e_.) + (f_.)*(x_)], x_Symbol] :> Simp[((c + d*x)^(m + 1)*Sin[e + f*x])/(d*(
m + 1)), x] - Dist[f/(d*(m + 1)), Int[(c + d*x)^(m + 1)*Cos[e + f*x], x], x] /; FreeQ[{c, d, e, f}, x] && LtQ[
m, -1]

Rule 3302

Int[sin[(e_.) + (f_.)*(x_)]/((c_.) + (d_.)*(x_)), x_Symbol] :> Simp[CosIntegral[e - Pi/2 + f*x]/d, x] /; FreeQ
[{c, d, e, f}, x] && EqQ[d*(e - Pi/2) - c*f, 0]

Rubi steps

\begin{align*} \int \frac{\cos (x) \sin (x)}{x^2} \, dx &=\int \frac{\sin (2 x)}{2 x^2} \, dx\\ &=\frac{1}{2} \int \frac{\sin (2 x)}{x^2} \, dx\\ &=-\frac{\sin (2 x)}{2 x}+\int \frac{\cos (2 x)}{x} \, dx\\ &=\text{Ci}(2 x)-\frac{\sin (2 x)}{2 x}\\ \end{align*}

Mathematica [A]  time = 0.0060185, size = 16, normalized size = 1. \[ \text{CosIntegral}(2 x)-\frac{\sin (2 x)}{2 x} \]

Antiderivative was successfully verified.

[In]

Integrate[(Cos[x]*Sin[x])/x^2,x]

[Out]

CosIntegral[2*x] - Sin[2*x]/(2*x)

________________________________________________________________________________________

Maple [A]  time = 0.026, size = 15, normalized size = 0.9 \begin{align*}{\it Ci} \left ( 2\,x \right ) -{\frac{\sin \left ( 2\,x \right ) }{2\,x}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(cos(x)*sin(x)/x^2,x)

[Out]

Ci(2*x)-1/2*sin(2*x)/x

________________________________________________________________________________________

Maxima [C]  time = 1.20794, size = 20, normalized size = 1.25 \begin{align*} \frac{1}{2} \, \Gamma \left (-1, 2 i \, x\right ) + \frac{1}{2} \, \Gamma \left (-1, -2 i \, x\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(x)*sin(x)/x^2,x, algorithm="maxima")

[Out]

1/2*gamma(-1, 2*I*x) + 1/2*gamma(-1, -2*I*x)

________________________________________________________________________________________

Fricas [A]  time = 0.459234, size = 95, normalized size = 5.94 \begin{align*} \frac{x \operatorname{Ci}\left (2 \, x\right ) + x \operatorname{Ci}\left (-2 \, x\right ) - 2 \, \cos \left (x\right ) \sin \left (x\right )}{2 \, x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(x)*sin(x)/x^2,x, algorithm="fricas")

[Out]

1/2*(x*cos_integral(2*x) + x*cos_integral(-2*x) - 2*cos(x)*sin(x))/x

________________________________________________________________________________________

Sympy [A]  time = 2.15956, size = 22, normalized size = 1.38 \begin{align*} - \log{\left (x \right )} + \frac{\log{\left (x^{2} \right )}}{2} + \operatorname{Ci}{\left (2 x \right )} - \frac{\sin{\left (2 x \right )}}{2 x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(x)*sin(x)/x**2,x)

[Out]

-log(x) + log(x**2)/2 + Ci(2*x) - sin(2*x)/(2*x)

________________________________________________________________________________________

Giac [A]  time = 1.12137, size = 26, normalized size = 1.62 \begin{align*} \frac{2 \, x \operatorname{Ci}\left (2 \, x\right ) - \sin \left (2 \, x\right )}{2 \, x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(x)*sin(x)/x^2,x, algorithm="giac")

[Out]

1/2*(2*x*cos_integral(2*x) - sin(2*x))/x